1. Field of the Invention
The present invention relates generally to a frame relay apparatus and method for relaying frames, arranged in a network, and more particularly, to a frame relay apparatus for relaying frames so as to obviate an infinite loop of frames which may occur in a looped transmission path.
2. Description of the Relates Art
A typical relay apparatus arranged on an IP network such as Internet or Intranet has hitherto been provided with a function to relay frames depending on MAC addresses that provide the second layer (L2). This frame relay function is called an L2 switching function or simply an L2 switch. The LAN protocols advance toward the integration with the IP protocols. In the network consisting of LAN apparatuses, when a part of the network is cut off, communication may be interrupted and its reliability may be impaired. For the purpose of improving the network reliability, a looped transmission path based redundant structure is built up so as not to interrupt the communication in spite of any possible partial cutoff of the network.
In case of provision of the looped transmission path based redundant structure, there may occur an infinite loop that causes the iteration of the frame transmission in the loop passing through specific L2 switches although the network reliability can be improved. Occurrence of the frame infinite loop may possibly result in a risk of the entire LAN going down. The standardized and prevailing spanning tree is a conventional method for obviating the occurrence of the infinite loop of frames in the LAN. The spanning tree is a technique allowing all the L2 switches to fully post on their own existence periodically and to grasp the loop structure, leaving only one port not dealing in frame sending and reception in the looped LAN.
Referring to FIG. 1A is shown a LAN spanning tree composed of the L2 switches by way of example. This spanning tree includes four personal computers 100-1 to 100-4 acting as nodes which are looped by use of four L2 switches 102-1 to 102-4, with a path extending between the switches 102-1 and 102-3 being severed to allow therein the formation of only one port not dealing in the frame sending and reception. In such a spanning tree, when a cutoff 104 occurs between the L2 switches 102-1 and 102-3 as in FIG. 1B for example, the L2 switch 102-1 judges the cutoff 104 of the network from the absence of information from the L2 switches 102-3 and 102-4 to be sent periodically. When the L2 switch detects the cutoff, the sending and reception by the port for the L2 switch 102-2, that has hitherto been idle, commence to obviate the entire communication break. However, since the spanning tree judges the cutoff of the network from the absence of the information from the L2 switches, if a communication break is erroneously recognized owing to e.g., the loads in the L2 switches or in the transmission path or to the bug of the L2 switches, the looped transfer path is formed as in FIG. 1C, which may eventually cause an infinite loop in the network.
According to the present invention there is provided a frame relay apparatus and method for judging and obviating the occurrence of a frame infinite loop through analysis of a received frame without relying on the other apparatuses.
According to the present invention there is provided a frame relay apparatus and method for obviating the occurrence of a frame infinite loop in a network which relays frames in conformity with MAC addresses (layer 2 addresses).
The present invention is directed to a frame relay apparatus for relaying frames, arranged in a network including a looped transmission path. The frame relay apparatus of the present invention comprises a frame reception unit for receiving a frame; a frame sending unit for sending a frame; an entry processing unit for entering into a table the frame information and the reception time received by the frame reception unit; a loop judgment unit for referring to the table upon the receipt of a frame by the frame reception unit, to detect a second receipt of the same frame to judge the occurrence of a loop; and a frame processing unit for allowing a received frame to be sent from the frame sending unit when no loop occurrence is judged, but discarding the received frame without sending the same when a loop occurrence is judged. In this manner, without relying on the other apparatuses as in the conventional spanning tree, the frame relay apparatus of the present invention analyzes the received frames by itself to judge the occurrence of an infinite loop to thereby discard the received frames in order to securely obviate the occurrence of the infinite loop, thus building up a highly reliable LAN.
The entry processing unit enters the frame information together with the reception time into the table, the frame information including a source address of an IP frame received by a second layer IP protocol, an ID indicative of a packet sending sequence, and a fragment offset indicative of a segmented position when the ID has the same value. In such an event, the loop judgment unit, in case the received IP frame source address has already been entered in the table, judges whether a received ID is equal to an entered ID, the loop judgment unit when the received ID is not equal to the entered ID, judging that a loop has occurred if a predetermined conditional expression is satisfied, the loop judgment unit when the received ID is equal to the entered ID, judging that a loop has occurred if a received fragment offset is equal to an entered fragment offset.
The conditional expression for the frame processing unit is used to judge that a loop has occurred if a predetermined maximum packet transfer speed is exceeded by a calculated packet transfer speed PPS of a received frame and an entered frame. More specifically, the conditional expression for the frame processing unit is given, when ID (n) greater than ID (nxe2x88x921), as
{ID(n)xe2x88x92ID(nxe2x88x921)}/{T(n)xe2x88x92T(nxe2x88x921)} greater than MAXPPS
where ID (n) is the value of a received ID, ID (nxe2x88x921) is the value of an entered ID, IDMAX is the maximum value of the ID, T (n) is the reception time, T (nxe2x88x921) is the entered reception time, and MAXPPS is the predetermined maximum packet transfer speed, and if the conditional expression is satisfied, then judgment is made that a loop has occurred. The conditional expression for the frame processing unit is given, when ID (n)xe2x89xa6ID (nxe2x88x921), as
{IDMAX+ID(n)xe2x88x92ID(nxe2x88x921)}/{T(n)xe2x88x92T(nxe2x88x921)} greater than MAXPPS
and, if the conditional expression is satisfied, then judgment is made that a loop has occurred. The frame processing unit when judging that a loop has occurred, discards only a received frame of which second receipt has been detected. The frame processing unit when judging that a loop has occurred, suspends the frame relay for a constant period of time, after the discard of a received frame of which second receipt has been detected.
To obviate the occurrence of the infinite loop, the frame relay apparatus of the present invention is arranged on a looped transmission path formed by L3 switches disposed at the boundary of a virtual local area network (hereinafter, referred to as VLAN) which limits the broadcast frame transfer to the interior of the group. In case of provision of the frame relay apparatus of the present invention at the boundary of the LVAN, the entry processing unit enters frame information together with the reception time into the table, the frame information including a source address of an IP frame received by a third layer IP protocol, an ID indicative of a packet sending sequence, and a fragment offset indicative of positions segmented when the ID has the same value, the entry processing unit further entering into the table a virtual LAN tagged frame identifier VID received by the second layer protocol. Similar to the case of the ordinary VLAN, the loop judgment unit, in case the received IP frame source address has already been entered in the table, judges whether a received ID is equal to an entered ID, the loop judgment unit when the received ID is not equal to the entered ID, judging that a loop has occurred if a conditional expression based on the reception time and entered time is satisfied, the loop judgment unit when the received ID is equal to the entered ID, judging that a loop has occurred if a received fragment offset is equal to an entered fragment offset. When judging that a loop has occurred, the frame processing unit adapted for VLAN discards only a received frame of a VLAN of which second receipt has been detected. When judging that a loop has occurred, the frame processing unit may discard a received frame of the VLAN of which second receipt has been detected, to thereafter suspend the relay of a frame having the same VLAN identifier VID for a constant period of time. Even though the loop judged VLAN is identified from VID for discard of the received frame in this manner, normal VLAN frames flowing simultaneously through the boundary between the two VLAN can intactly be relayed in such a manner as to obviate the occurrence of an infinite loop without adversely affecting the other VLANs.
According to the present invention, there is provided a frame relay method for relaying a frame, applied to a network including a looped transmission path, the method comprising a table entry step for entering into a table the frame information and reception time of a frame received through a port; a loop judgment step for referring to the table upon a receipt of a frame through the port, to detect a second receipt of the same frame to thereby make a judgment that a loop has occurred; and a frame processing step for sending a received frame to another port unless it is judged that a loop has occurred, but discarding the received frame without sending the same when it is judged that a loop has occurred. The details of this frame relay method are basically the same as the case of the apparatus configuration.
The above and other objects, aspects, features and advantages of the present invention will become more apparent from the following detailed description when read in conjunction with the accompanying drawings.